import React from 'react';
import styles from './index.less';
import logo from '@/assets/logo.png';
import classnames from 'classnames';
import { useModel } from 'umi';

const MenuHeader: React.FC<{}> = () => {
  const { initialState } = useModel('@@initialState');
  return (
    <div className={styles['menu-header-wrap']}>
      <div className={classnames(styles['logo-wrap'], initialState?.collapsed && styles['fold'])}>
        <img src={logo} className={styles['logo']} />
      </div>
    </div>
  );
};
export default MenuHeader;
